<template>
	<view class="entrust_content">
		
		<view class="entrust_list" v-for="(entrust,index) in entrustList" :key="index">
			<view class="entrust_tips">恭喜您已成功委托上架，请查看订单详情</view>
			<view class="entrust_p">订单数量<text class="entrust_p_right">1</text></view>
			<view class="entrust_p">生成时间<text class="entrust_p_right">{{entrust.createTime}}</text></view>
			<view class="entrust_p">服务费用<text class="entrust_p_right">{{entrust.serviceCharge}}元</text></view>
			<view class="entrust_p">支付凭证码<text class="entrust_p_right">{{entrust.voucherCode}}</text></view>
			<view class="to_detail" @click="toDetail">
				<view class="see_detail">查看详情</view>
				<image class="see_detail_icon" src="../../static/right_jiantou.png" mode=""></image>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				entrustList:[]
			}
		},
		onLoad() {
			this.getEntrust();
		},
		methods: {
			toDetail(){
				
				uni.navigateTo({
					url: '/pages/entrust/entrustDetail/entrustDetail'
				})
			},
			
			getEntrust(){
				const that = this
				that.$api.request('/system/order','/list', {
				
				}, (failres => {
					uni.showToast({
						title:failres.msg
					})
					that.registering = false
				})).then(res => {
					//注册成功
					that.entrustList=res.rows
				})
			},
		}
	}
</script>

<style lang="scss">
	.entrust_content{
		width: 100%;
		min-height: 100vh;
		background: #F6F6F6;
		padding-top: 30upx;
		.entrust_list{
			width: 100%;
			background: #FFFFFF;
			padding: 20upx 0;
			margin-bottom: 30upx;
			.entrust_tips{
				border-bottom: 1upx solid #F8F8F8;
				padding-left: 30upx;
				height: 70upx;
				line-height: 70upx;
				font-size: 28upx;
				color: #666666;
				padding-bottom: 20upx;
			}
			.entrust_p{
				padding-left: 30upx;
				height: 70upx;
				line-height: 70upx;
				font-size: 28upx;
				color: #666666;
				.entrust_p_right{
					display: inline-block;
					color: #ff2d51;
					margin-left: 80upx;
				}
			}
			.to_detail{
				margin-top: 50upx;
				margin-bottom: 10upx;
				display: flex;
				align-items: center;
				justify-content: space-between;
				.see_detail{
					color: red;
					font-size: 28upx;
					padding-left: 30upx;
				}
				.see_detail_icon{
					width: 30upx;
					height: 30upx;
					margin-right: 30upx;
				}
			}
		}
	}
</style>
